Wellbore instability and time delayed failures due to interaction between a drilling fluid and geologic formation (for example, shale) while drilling may cause problems, both technical and financial, in drilling procedures. For example, borehole instability in geologic formations, such as shales, may increase problems, time, and cost during drilling. Problems may be time dependent, as they build up over time, such as swelling in shales during drilling. Consequences may include losing the hole in the wellbore (for example, collapse), having to manage a well control situation, or having to sidetrack. Technologies such as horizontal drilling, slim-hole drilling, and coiled-tubing drilling may not resolve borehole instability problems and, indeed, they may lead to at least as many problems as conventional drilling. Borehole instability in various geological formations may be a complex phenomenon, because certain rock formations, when in contact with water-based drilling fluids, can absorb water and ions can cause wellbore instability leading to the aforementioned issues.